<?php

namespace App\Models;

use App\Models\BaseModel;

class Menu extends BaseModel
{

    protected $table = 'menus';

    protected $fillable = [
        'parentId',
        'name',
        'visible',
        'icon',
        'sort',
        'routeName',
        'routePath',
        'component',
        'redirect',
        'type',
        'perm',
        'keepAlive',
        'alwaysShow',
        'params',
    ];

    protected function casts()
    {
        return [
            'params' => 'json'
        ];
    }
}
